#!/usr/bin/env python
# -*- coding: UTF-8 -*-
#__email__ = "wjx010107@163.com"
#__author__ = "weijinxing"



"""atsystem URL Configuration

The `urlpatterns` list routes URLs to views. For more information please see:
    https://docs.djangoproject.com/en/1.8/topics/http/urls/
Examples:
Function views
    1. Add an import:  from my_app import views
    2. Add a URL to urlpatterns:  url(r'^$', views.home, name='home')
Class-based views
    1. Add an import:  from other_app.views import Home
    2. Add a URL to urlpatterns:  url(r'^$', Home.as_view(), name='home')
Including another URLconf
    1. Add an import:  from blog import urls as blog_urls
    2. Add a URL to urlpatterns:  url(r'^blog/', include(blog_urls))
"""
from django.conf.urls import include, url
from django.contrib import admin
from atsystem.settings import STATIC_URL
urlpatterns = [
#    url(r'^admin/', include(admin.site.urls)),
    url(r'^$', 'atsystem.views.login_at'),
    url(r'^login/$', 'atsystem.views.login_at'),
    url(r'^logout/$', 'atsystem.views.logout_at'),
    url(r'^admin/$', 'atsystem.views.admin'),
    url(r'^favicon\.ico$', 'django.views.generic.list.ListView', {'url': STATIC_URL+'images/favicon.ico'}),
    url(r'^test/$', 'atsystem.views.test'),
    url(r'^test2/$', 'atsystem.views.echo'),
    url(r'^admin/tasks/$', 'atsystem.views.task_list'),
    url(r'^admin/tasks/delete/(\w+)/$', 'atsystem.views.task_del'),
    url(r'^admin/tasks/profile/(\w+)/$', 'atsystem.views.task_profile'),
    url(r'^admin/tasks/update/$', 'atsystem.views.update_taskinfo'),
    url(r'^admin/tasks/task_add/$', 'atsystem.views.task_add'),
    url(r'^admin/tasks/interval_add/$', 'atsystem.views.interval_add'),
    url(r'^admin/tasks/crontab_add/$', 'atsystem.views.crontab_add'),
    url(r'^admin/host_exec/$', 'atsystem.views.host_exec'),
    url(r'^admin/jquery_tree/$', 'atsystem.views.dirlist'),
    url(r'^admin/file_copy/$', 'atsystem.views.file_copy'),
    url(r'^admin/file_copy/cp_exec/$', 'atsystem.views.cp_exec'),
    url(r'^admin/account/$', 'atsystem.views.account'),
    url(r'^admin/account/userinfo/(\w+)/$', 'atsystem.views.userinfo'),
    url(r'^admin/account/usercal/(\w+)/$', 'atsystem.views.usercalendar'),
    url(r'^admin/account/caladd/$', 'atsystem.views.caladd'),
    url(r'^admin/account/calview/$', 'atsystem.views.calview'),
    url(r'^admin/account/update/$', 'atsystem.views.update_userinfo'),
    url(r'^admin/account/userinfo/changepass/(\w+)/$', 'atsystem.views.change_pass'),
    url(r'^admin/account/useradd/$', 'atsystem.views.add_atuser'),
    url(r'^admin/account/del_user/(\w+)/$', 'atsystem.views.user_del'),
    url(r'^admin/groups/$', 'atsystem.views.group'),
    url(r'^admin/groups/groupadd/$', 'atsystem.views.add_group'),
    url(r'^admin/groups/groupinfo/(\w+)/$', 'atsystem.views.groupinfo'),
    url(r'^admin/groups/update/$', 'atsystem.views.update_groupinfo'),
    url(r'^admin/groups/del_group/(\w+)/$', 'atsystem.views.group_del'),
    url(r'^admin/hosts/$', 'atsystem.views.hosts_list'),
    url(r'^admin/hosts/hresource/(.+)/$', 'atsystem.views.host_resource'),
    url(r'^admin/hosts/update/$', 'atsystem.views.update_hosts_list'),
    url(r'^admin/hosts/addtomg/$', 'atsystem.views.host_to_mgroup'),
    url(r'^admin/hosts/shortfun/$', 'atsystem.views.shortfun'),
    url(r'^admin/mgroups/$', 'atsystem.views.mgroup_list'),
    url(r'^admin/mgroups/mgprofile/(\w+)/$', 'atsystem.views.mg_profile'),
    url(r'^admin/mgroups/update/$', 'atsystem.views.update_mg_profile'),
    url(r'^admin/mgroups/del_mg/(\w+)/$', 'atsystem.views.mg_del'),
    url(r'^admin/mgroups/mgroupadd/$', 'atsystem.views.add_mgroup'),
    url(r'^admin/execmd/$', 'atsystem.views.exec_html'),
    url(r'^admin/execmd/rescmd/$', 'atsystem.views.exec_cmd'),
    url(r'^admin/software/$', 'atsystem.views.softwarein'),
    url(r'^admin/software/insoftware/$', 'atsystem.views.in_software'),
]
